package com.huanong.it.xwcommon.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

@TableName("users")
public class User implements Serializable {
    @TableId("user_id")
    private int id;
    @TableField("user_nickname")
    private String nickName;
    @TableField("user_loginname")
    private String loginName;
    @TableField("user_loginpwd")
    private String loginPwd;
    @TableField("user_photo")
    private String photo;
    @TableField("user_score")
    private int score;
    @TableField("user_attioncount")
    private int attionCount;
    @TableField("user_state")
    private int state;

    //扩充的信息统统都放在Map中(例如从其他微服务拿来的外键对象)
    @TableField(exist = false)
    private Map<String,Object> map=new HashMap<>();
    public Map<String, Object> getMap() {
        return map;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public String getLoginName() {
        return loginName;
    }

    public void setLoginName(String loginName) {
        this.loginName = loginName;
    }

    public String getLoginPwd() {
        return loginPwd;
    }

    public void setLoginPwd(String loginPwd) {
        this.loginPwd = loginPwd;
    }

    public String getPhoto() {
        return photo;
    }

    public void setPhoto(String photo) {
        this.photo = photo;
    }

    public int getScore() {
        return score;
    }

    public void setScore(int score) {
        this.score = score;
    }

    public int getAttionCount() {
        return attionCount;
    }

    public void setAttionCount(int attionCount) {
        this.attionCount = attionCount;
    }

    public int getState() {
        return state;
    }

    public void setState(int state) {
        this.state = state;
    }
}
